package com.wyl.pmd.rule.errorprone;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.wyl.pmd.model.SomeException;

public class UseCorrectExceptionLogging {

	private static final Logger LOGGER = LoggerFactory.getLogger(UseCorrectExceptionLogging.class);

	void bar() {
		try {
		} catch (SomeException oe) {
			LOGGER.error(oe.getMessage()); // bad
			LOGGER.error(oe.getMessage(), oe); // good
		}
	}

}
